package cn.kgc.exception;

import cn.kgc.utils.IErrorCode;

public enum  UserErrorCode implements IErrorCode {

            User_No_EXIST("3001","用户不存在"),
            User_ERROR_PASSWORD("3002","用户密码不正确"),
            USER_NOT_LOGIN("3002","用戶沒有登录或者token过期"),
            TOKEN_NOT_TIMEOUT("3004","token没有在置换期,置换期指的是token有效期小于30分钟"),
            USER_CODE_EXIST("3005","登录验证码还在一分钟内,1分钟只能获取一次"),
            INVLIDE_REQ("3006","无效请求"),
            INVLIDE_CODE("3007","验证码不存在或者已经失效"),
            ERROR_LOGIN_CODE("3008","验证码错误,请重试");
    ;


    private String errorCode;
    private String errorMsg;


    UserErrorCode(String errorCode, String errorMsg) {
        this.errorCode = errorCode;
        this.errorMsg = errorMsg;
    }

    @Override
    public String getErrorCode() {
        return errorCode;
    }

    @Override
    public String getErrorMessage() {
        return errorMsg;
    }
}
